<?php
session_start();

if(isset($_SESSION['userid'])&&$_SESSION['level']!=2)
{
	
	header ("location: login.php");
	exit();
}
?>
<?
include("includes/top_user.php");
?>
<?
include("includes/connect.php");
$id=$_GET['threadid'];
$sql = "select * from thread,user where thread.id='".$id."' and thread.user_id=user.id";
$query = mysql_query($sql);
$row = mysql_fetch_array($query);
?>
<div id="box">
<h3>Thông tin bài viết</h3>
Mã bài viết : <? echo $row['id']."<br>"; ?>
Tiêu đề : <? echo $row['title']."<br>"; ?>
Nội dung :<br> <? echo $row['content']."<br>"; ?>
Tác giả : <? echo $row['username']."<br>"; ?>

</div>
<?
include("includes/sidebar.php");
include("includes/footer.php");
?>